<?php
/**
 * Created by PhpStorm.
 * User: ming
 * Date: 17-8-17
 * Time: 上午11:45
 */
swoole_process::signal(SIGALRM,function (){
   static $i=0;
   echo "$i \n";
   $i++;
   if ($i>10){
       swoole_process::alarm(-1);
   }
});

swoole_process::alarm(100*1000);